package com.acs.code5.service;

import com.acs.code5.common.PageCondition;
import com.acs.code5.common.PageModel;
import com.acs.code5.common.dto.PermissionDTO;
import com.acs.code5.common.dto.RoleDTO;

import java.util.List;

public interface RoleService {
    PageModel<RoleDTO> listAllRole(PageCondition condition);

    RoleDTO create(String roleName);

    RoleDTO update(String roleName, Integer roleId);

    void delete(Integer roleId);

    PageModel<PermissionDTO> listRolePermissions(Integer roleId, PageCondition condition);

    void assignPermissions(Integer roleId, List<Integer> permisIdList);
}
